<%@ taglib prefix="c" uri="http://java.sun.com/jsp/jstl/core" %>
<%@ page contentType="text/html;charset=UTF-8" language="java" %>
<html>
<head>
    <title>查看并审核App信息页</title>
    <%@ include file="/basePath.jsp" %>
    <meta name="viewport" content="width=device-width,initial-scale=1,shrink-to-fit=no"/>
    <link rel="stylesheet" href="statics/bootstrap/css/bootstrap.css">
</head>
<body>
<script src="statics/js/jquery-3.6.0.js"></script>
<script src="statics/bootstrap/js/bootstrap.js"></script>

<div class="container-fluid" style="min-width: 1000px;">
    <div id="header" class="p-3 border">
        <h1 style="font-size: 18px;">查看App基础信息<small class="ml-3 text-danger">用户：${devName}</small>
        </h1>
    </div>
    <div class="p-3 border">
        <form class="w-75 m-auto form" action="" method="post" enctype="multipart/form-data" style="font-size: 14px;">
                <div class="form-group form-row">
                    <label for="softwareName" class="col-3">软件名称:</label>
                    <input type="text" class="form-control col-5" id="softwareName" name="softwareName"
                           value="${appInfo[0].softwareName}" readonly>
                </div>
                <div class="form-group form-row">
                    <label for="apkName" class="col-3">APK名称:</label>
                    <input type="text" class="form-control col-5" id="apkName" name="apkName"
                           value="${appInfo[0].apkName}" readonly>
                </div>
                <div class="form-group form-row">
                    <label for="supportRom" class="col-3">支持ROM:</label>
                    <input type="text" class="form-control col-5" id="supportRom" name="supportRom"
                           value="${appInfo[0].supportRom}" readonly>
                </div>
                <div class="form-group form-row">
                    <label for="interfaceLanguage" class="col-3">界面语言:</label>
                    <input type="text" class="form-control col-5" id="interfaceLanguage" name="interfaceLanguage"
                           value="${appInfo[0].interfaceLanguage}" readonly>
                </div>
                <div class="form-group form-row">
                    <label for="sofewareSize" class="col-3">软件大小:</label>
                    <input type="text" class="form-control col-5" id="sofewareSize" name="sofewareSize"
                           value="${appInfo[0].sofewareSize}" readonly>
                </div>
                <div class="form-group form-row">
                    <label for="downloads" class="col-3">下载次数:</label>
                    <input type="text" class="form-control col-5" id="downloads" name="downloads"
                           value="${appInfo[0].downloads}" readonly>
                </div>
                <div class="form-group form-row ">
                    <label for="flatformId" class="col-3">所属平台:</label>
                    <input type="text" class="form-control col-5" id="flatformId" name="flatformId"
                           value="${appInfo[0].flatform.flatform}" readonly>
                </div>

            <div class="form-group form-row ">
                <label for="level" class="col-3">所属分类:</label>
                <input type="text" class="form-control col-5" id="level" name="level"
                       value=" ${appInfo[0].categoryLevel1.name} -> ${appInfo[0].categoryLevel2.name} -> ${appInfo[0].categoryLevel3.name}" readonly>
            </div>
            <div class="form-group  form-row">
                <label for="status" class="col-3">APP状态:</label>
                <input type="text" class="form-control col-5" name="status" id="status"
                       value="${appInfo[0].status.status}" readonly>
            </div>
            <div class="form-group  form-row">
                <label for="appInfo" class="col-3">应用简介:</label>
                <textarea class="form-control col-5" cols="50" rows="4" name="appInfo"
                          id="appInfo" readonly>${appInfo[0].appInfo}</textarea>
            </div>
            <div class="form-group  form-row" >
                <label class="col-3">LOGO图片:</label>
                <div id="logo" class="col-9">
                    <c:if test="${logoPathImg != null}">
                        <img class="form-control" style="height: 100px;width: 100px;" name="logoPathImg2"
                             id="logoPathImg"
                             src="${logoPathImg}">
                    </c:if>
                    <c:if test="${logoPathImg == null}">
                        <input type="text"  name="logoPath" id="logoPath2" value="没有添加logo图片" readonly>
                    </c:if>
                </div>
            </div>
        </form>
    </div>
    <div class="m-auto">
        <a class="btn btn-primary" style="margin-left: 300px;" href="updateStatus/${appInfo[0].id}/2/${pageNumber}">审核通过</a>
        <a class="btn btn-primary"  href="updateStatus/${appInfo[0].id}/3/${pageNumber}">审核不通过</a>
        <a class="btn btn-primary"  href="backendlist/${pageNumber}">返回</a>
    </div>
    <div id="resultList" class="border table-responsive p-3">
        <h2 class="p-2">最新版本信息</h2>
        <form class="w-75 m-auto" action="" method="post" enctype="multipart/form-data">
            <div class="form-group form-row">
                <label for="versionNo" class="col-3">版本号:</label>
                <input type="text" class="form-control col-5" id="versionNo" name="versionNo" value="${versions.versionNo}" readonly>
                <span class="col-4">error</span>
            </div>
            <div class="form-group form-row">
                <label for="versionSize" class="col-3">版本大小:</label>
                <input type="text" class="form-control col-5" id="versionSize" name="versionSize" value="${versions.versionSize}" readonly>
                <span class="col-4">error</span>
            </div>
            <div class="form-group  form-row">
                <label for="publishstatus" class="col-3">发布状态:</label>
                <input type="text" class="form-control col-5" name="publishstatus" id="publishstatus" readonly value="预发布">
                <span class="col-4">error</span>
            </div>
            <div class="form-group  form-row">
                <label for="versionInfo" class="col-3">版本简介:</label>
                <textarea class="form-control col-5" cols="50" rows="4" name="versionInfo" id="versionInfo"  readonly>${versions.versionInfo}</textarea>
                <span class="col-4">error</span>
            </div>
            <div class="form-group  form-row">
                <label for="apkLocPath" class="col-3">apk文件:</label>
                <input class="form-control col-5" type="text" name="apkLocPath" id="apkLocPath" value="${versions.apkLocPath}" readonly></input>
                <c:if test="${versions.apkLocPath != null}">
                    <a href="${versions.apkLocPath}" class="">下载</a>
                </c:if>
            </div>
        </form>
    </div>

</div>
</body>
</html>
